package com.jshoperxms.entity;

import javax.persistence.*;

/**
 * Created by sdywcd on 2018/12/12.
 * Des:
 */
@Entity
@Table(name = "yd_ancient_questions_t", schema = "jshoperxms", catalog = "")
public class YdAncientQuestionsT {
    private String id;
    private String status;
    private long createtime;
    private String creatorid;
    private long updatetime;
    private int versiont;
    private String anctitle;
    private String ancitemcontent;
    private String wxopenid;
    private int ancnumber;
    private String anclevel;
    private int usedamount;
    private String ancqatitle;
    private String ancanswer;

    @Id
    @Column(name = "ID", nullable = false, length = 25)
    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    @Basic
    @Column(name = "STATUS", nullable = false, length = 1)
    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    @Basic
    @Column(name = "CREATETIME", nullable = false)
    public long getCreatetime() {
        return createtime;
    }

    public void setCreatetime(long createtime) {
        this.createtime = createtime;
    }

    @Basic
    @Column(name = "CREATORID", nullable = false, length = 25)
    public String getCreatorid() {
        return creatorid;
    }

    public void setCreatorid(String creatorid) {
        this.creatorid = creatorid;
    }

    @Basic
    @Column(name = "UPDATETIME", nullable = false)
    public long getUpdatetime() {
        return updatetime;
    }

    public void setUpdatetime(long updatetime) {
        this.updatetime = updatetime;
    }

    @Basic
    @Column(name = "VERSIONT", nullable = false)
    public int getVersiont() {
        return versiont;
    }

    public void setVersiont(int versiont) {
        this.versiont = versiont;
    }

    @Basic
    @Column(name = "ANCTITLE", nullable = false, length = 100)
    public String getAnctitle() {
        return anctitle;
    }

    public void setAnctitle(String anctitle) {
        this.anctitle = anctitle;
    }

    @Basic
    @Column(name = "ANCITEMCONTENT", nullable = false, length = 1000)
    public String getAncitemcontent() {
        return ancitemcontent;
    }

    public void setAncitemcontent(String ancitemcontent) {
        this.ancitemcontent = ancitemcontent;
    }

    @Basic
    @Column(name = "WXOPENID", nullable = false, length = 45)
    public String getWxopenid() {
        return wxopenid;
    }

    public void setWxopenid(String wxopenid) {
        this.wxopenid = wxopenid;
    }


    @Basic
    @Column(name = "ANCNUMBER", nullable = false)
    public int getAncnumber() {
        return ancnumber;
    }

    public void setAncnumber(int ancnumber) {
        this.ancnumber = ancnumber;
    }

    @Basic
    @Column(name = "ANCLEVEL", nullable = false, length = 1)
    public String getAnclevel() {
        return anclevel;
    }

    public void setAnclevel(String anclevel) {
        this.anclevel = anclevel;
    }

    @Basic
    @Column(name = "USEDAMOUNT", nullable = false)
    public int getUsedamount() {
        return usedamount;
    }

    public void setUsedamount(int usedamount) {
        this.usedamount = usedamount;
    }

    @Basic
    @Column(name = "ANCQATITLE", nullable = false, length = 100)
    public String getAncqatitle() {
        return ancqatitle;
    }

    public void setAncqatitle(String ancqatitle) {
        this.ancqatitle = ancqatitle;
    }

    @Basic
    @Column(name = "ANCANSWER", nullable = false, length = 100)
    public String getAncanswer() {
        return ancanswer;
    }

    public void setAncanswer(String ancanswer) {
        this.ancanswer = ancanswer;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        YdAncientQuestionsT that = (YdAncientQuestionsT) o;

        if (createtime != that.createtime) return false;
        if (updatetime != that.updatetime) return false;
        if (versiont != that.versiont) return false;
        if (ancnumber != that.ancnumber) return false;
        if (usedamount != that.usedamount) return false;
        if (id != null ? !id.equals(that.id) : that.id != null) return false;
        if (status != null ? !status.equals(that.status) : that.status != null) return false;
        if (creatorid != null ? !creatorid.equals(that.creatorid) : that.creatorid != null) return false;
        if (anctitle != null ? !anctitle.equals(that.anctitle) : that.anctitle != null) return false;
        if (ancitemcontent != null ? !ancitemcontent.equals(that.ancitemcontent) : that.ancitemcontent != null)
            return false;
        if (wxopenid != null ? !wxopenid.equals(that.wxopenid) : that.wxopenid != null) return false;
        if (anclevel != null ? !anclevel.equals(that.anclevel) : that.anclevel != null) return false;
        if (ancqatitle != null ? !ancqatitle.equals(that.ancqatitle) : that.ancqatitle != null) return false;
        if (ancanswer != null ? !ancanswer.equals(that.ancanswer) : that.ancanswer != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = id != null ? id.hashCode() : 0;
        result = 31 * result + (status != null ? status.hashCode() : 0);
        result = 31 * result + (int) (createtime ^ (createtime >>> 32));
        result = 31 * result + (creatorid != null ? creatorid.hashCode() : 0);
        result = 31 * result + (int) (updatetime ^ (updatetime >>> 32));
        result = 31 * result + versiont;
        result = 31 * result + (anctitle != null ? anctitle.hashCode() : 0);
        result = 31 * result + (ancitemcontent != null ? ancitemcontent.hashCode() : 0);
        result = 31 * result + (wxopenid != null ? wxopenid.hashCode() : 0);
        result = 31 * result + ancnumber;
        result = 31 * result + (anclevel != null ? anclevel.hashCode() : 0);
        result = 31 * result + usedamount;
        result = 31 * result + (ancqatitle != null ? ancqatitle.hashCode() : 0);
        result = 31 * result + (ancanswer != null ? ancanswer.hashCode() : 0);
        return result;
    }
}
